<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<%@ include file="./tag.jsp"%>
<head>
<title>LG最天使评选活动</title>
<style type="text/css">
<!--
body {
	background-color: #F5C418;
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
-->
</style>
<link href="../../../sys/css/angel/css.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.STYLE2 {color: #000000}
.STYLE3 {color: #FFFFFF}
-->
</style>
<script src="${ctx }/js/jquery.js" type="text/javascript"></script>
<script type="text/javascript">
	$(function(){
		$("#savebtn").click(function (){
			var regId = $("#regId").val();
			var userPw = $("#userPw").val();
			var content = $("#content").val();
			
			if(regId.trim()==''||userPw.trim()==''){
				alert('用户名和密码不能为空');
				return ;
			}else if(content.trim()==''){
				alert('评论内容不能为空');
				return ;
			}
			$.get("judgeUser.do", { regId: regId, userPw: userPw },function(data){
			
				if(data=='0'){
					alert('用户名或密码不正确');
					return ;
				}else{
					$("#f2").submit();
				}
			});
			
		});
	});
	function edit(){
		var textarea = $("<textarea rows='6' cols='50' onblur='save(this.value);' ></textarea>");
		textarea.val($("#description").html());
		$("#description").html('');
		textarea.appendTo($("#description"));
	}
	
	function save(value){
		$.post('updateUser.do',{'description':value});
		$("#description").html(value);
	}
	
	function showBig(filepath){
		$("#bigPicture").attr("src",filepath);
	}
	
</script>
</head>

<body>
<table width="950" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="951" align="center"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="950" height="540">
      <param name="movie" value="../../../sys/images/angel/images/banner.swf" />
      <param name="quality" value="high" />
      <embed src="../../../sys/images/angel/images/banner.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="950" height="540"></embed>
    </object></td>
  </tr>
</table>
<table width="1010" height="79" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td align="center" valign="bottom" background="../../../sys/images/angel/images/table-bg.gif"><table width="70%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td height="40">
		    <a href="#"><img src="../../../sys/images/angel/images/title-01.gif" width="120" height="39" border="0" /></a></td>
        <td><img src="../../../sys/images/angel/images/table-01.gif" width="2" height="38" /></td>
        <td><a href="#"><img src="../../../sys/images/angel/images/title-02.gif" width="120" height="39" border="0" /></a></td>
        <td><img src="../../../sys/images/angel/images/table-01.gif" width="2" height="38" /></td>
        <td><a href="#"><img src="../../../sys/images/angel/images/title-03.gif" width="120" height="39" border="0" /></a></td>
        <td><img src="../../../sys/images/angel/images/table-01.gif" width="2" height="38" /></td>
        <td><a href="#"><img src="../../../sys/images/angel/images/title-04.gif" width="120" height="39" border="0" /></a></td>
        <td><img src="../../../sys/images/angel/images/table-01.gif" width="2" height="38" /></td>
        <td><a href="#"><img src="../../../sys/images/angel/images/title-05.gif" width="120" height="39" border="0" /></a></td>
        <td><img src="../../../sys/images/angel/images/table-01.gif" width="2" height="38" /></td>
        <td><a href="#"><img src="../../../sys/images/angel/images/title-06.gif" width="120" height="39" border="0" /></a></td>
      </tr>
      
    </table></td>
  </tr>
</table>
<table width="950" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="15" align="center" valign="bottom" background="../../../sys/images/angel/images/02-02-bg-1.gif" bgcolor="#FFFFFF"><img src="../../../sys/images/angel/images/02-02-bg-1.gif" width="2" height="15" /></td>
  </tr>
</table>
<table width="950" height="276" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <tr>
    <td align="center" valign="top" background="../../../sys/images/angel/images/02-02-bg.gif" id="ty00"><table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:11px">
      <tr>
        <td align="left"><img src="../../../sys/images/angel/images/02-02-01-1.gif" width="244" height="22" /><c:if test="${user.promoterId eq param.userid}"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#" >编辑</a>
		&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#" onclick="edit();" >编辑</a></c:if>
		</td>
      </tr>
      
    </table>
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:11px">
      <tr>
        <td width="50%" align="left"><img src="../../../sys/images/angel/images/02-02-02-1.gif" width="415" height="22" /></td>
        <td width="50%" align="left"><img src="../../../sys/images/angel/images/02-02-02-2.gif" width="415" height="22" /></td>
      </tr>
      <tr>
        <td align="left">
		<table width="100%" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
            <tr>
              <td width="120"><img src="${ctx }${angel.filepath }" width="100" height="130" class="photo-3-04" /></td>
              <td valign="top"><table width="97%" border="0" cellpadding="0" cellspacing="0" class="song-12-20">
                <tr>
                  <td id="zhong-B">昵　　称：${angel.nkName }</td>
                </tr>
                <tr>
                  <td id="zhong-B">所属门店：${angel.shopNm }</td>
                </tr>
                <tr>
                  <td id="zhong-B">所属城市：${angel.cityIn }</td>
                </tr>
                <tr>
                  <td id="zhong-B">性　　别：<c:if test="${angel.gener eq 'M' }">女</c:if><c:if test="${angel.gener eq 'F' }">男</c:if> </td>
                </tr>
                <tr>
                  <td id="zhong-B">销售指数：★★☆☆☆${angel.sales }</td>
                </tr>
                <tr>
                  <td id="zhong-B">活跃指数：★★★★☆${angel.loginTm }</td>
                </tr>
                <tr>
                  <td id="zhong-B">博客地址：${angel.blog }</td>
                </tr>
              </table></td>
            </tr>
          </table>
		  </td>
        <td align="left" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
          <tr>
            <td id="description" class="song-12-20" >${angel.description }</td>
            </tr>
          <tr>
            <td class="song-12-20"><br />
              <span class="STYLE1">(自我描述内容可以是：个人性格，兴趣爱好，血型星座等)</span></td>
            </tr>
        </table></td>
      </tr>
    </table>
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td align="left" background="../../../sys/images/angel/images/02-02-03-bg.gif"><img src="../../../sys/images/angel/images/02-02-03-1.gif" width="376" height="46" /></td>
        <td width="65" align="right" background="../../../sys/images/angel/images/02-02-03-bg.gif"><img src="../../../sys/images/angel/images/02-02-03-2.gif" width="65" height="46" /></td>
      </tr>
    </table>
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td width="492" height="430" align="left" valign="top" background="../../../sys/images/angel/images/02-02-04-1.gif">
		<table width="427" height="240" border="0" cellpadding="0" cellspacing="0" style="margin:30px 0px 0px 33px">
          <tr>
            <td align="center" valign="middle"><img src="../../../sys/images/angel/images/02-02-phtot-03.gif" width="427" height="240" /></td>
          </tr>
        </table></td>
        <td align="center"><!-- <img id="bigPicture" src="../../../sys/images/angel/images/02-02-04-2.gif" width="16" height="384" /> -->
        	<img id="bigPicture" src="${photos.modelList[0].filepath }" width="16" height="384" />
        </td>
        <td width="325" align="center">
        <table width="85%" border="0" cellspacing="0" cellpadding="0">
          <tr>
          	<c:forEach items="${photos.modelList}" var="photo" begin="0" end="2" >
            <td><img src="${photo.filepath}" width="76" height="76" class="photo-3-05" onclick="showBig(${ctx}${photo.filepath});" /></td>
            </c:forEach>
            </tr>
            <c:if test="${user.promoterId eq param.userid}">
			<tr>
			<c:forEach items="${photos.modelList}" var="photo" begin="0" end="2" >
				<td><a href="${ctx }/delPhoto.do?pictureId=${photo.pictureId}&filepath=${photo.filepath}" >删除</a></td>
				</c:forEach>
			</tr>
			</c:if>
          <tr>
          <tr>
          	<c:forEach items="${photos.modelList}" var="photo" begin="3" end="5" >
            <td><img src="${photo.filepath}" width="76" height="76" class="photo-3-05" onclick="showBig(${ctx}${photo.filepath});" /></td>
            </c:forEach>
            </tr>
            <c:if test="${user.promoterId eq param.userid}">
			<tr>
			<c:forEach items="${photos.modelList}" var="photo" begin="3" end="5" >
				<td><a href="${ctx }/delPhoto.do?pictureId=${photo.pictureId}&filepath=${photo.filepath}" >删除</a></td>
				</c:forEach>
			</tr>
            </c:if>
          <tr>
          	<c:forEach items="${photos.modelList}" var="photo" begin="6" end="8" >
            <td><img src="${photo.filepath}" width="76" height="76" class="photo-3-05" onclick="showBig(${ctx}${photo.filepath});" /></td>
            </c:forEach>
            </tr>
            <c:if test="${user.promoterId eq param.userid}">
			<tr>
			<c:forEach items="${photos.modelList}" var="photo" begin="6" end="8" >
				<td><a href="${ctx }/delPhoto.do?pictureId=${photo.pictureId}&filepath=${photo.filepath}"  >删除</a></td>
				</c:forEach>
			</tr>
			</c:if>
          <tr>
          	<c:forEach items="${photos.modelList}" var="photo" begin="9" end="11" >
            <td><img src="${ctx }${photo.filepath}" width="76" height="76" class="photo-3-05" onclick="showBig(${ctx}${photo.filepath});" /></td>
            </c:forEach>
            </tr>
            <c:if test="${user.promoterId eq param.userid}">
			<tr>
			<c:forEach items="${photos.modelList}" var="photo" begin="9" end="11" >
				<td><a href="${ctx }/delPhoto.do?pictureId=${photo.pictureId}&filepath=${photo.filepath}" >删除</a></td>
				</c:forEach>
			</tr>
			</c:if>
        </table>
          <table width="85%" border="0" cellspacing="0" cellpadding="0">
            <tr>
              <td align="center"><!-- <a href="#" >上一组</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#" >下一组</a> -->
              <!-- 	<pg:page formAction="personspace.do?type=photos"
								onePageCount="${photos.onePageCount}"
								resultCount="${photos.resultCount}"
								currentPage="${photos.currentPage}" isShowInfo="true" /> -->
              </td>
              </tr>
          </table></td>
      </tr>
    </table>
    <c:forEach items="${commemts.modeList}" var="comment" >
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td align="left" valign="top" background="../../../sys/images/angel/images/02-02-05-2.gif"><img src="../../../sys/images/angel/images/02-02-05-1.gif" width="151" height="22" /></td>
        </tr>
      <tr>
        <td height="35" align="left" bgcolor="#F6F6F6" class="ab10-12" id="zhong-A"><strong><c:choose>
        	<c:when test="${ empty comment.userId}">匿名网友</c:when>
        	<c:otherwise>${comment.nkName }</c:otherwise>
        </c:choose> </strong> 来自: ( <fmt:formatDate value="${comment.commentDt}" pattern="yyyy-MM-dd" /> ) 留言：</td>
        </tr>
      <tr>
        <td height="35" align="center" valign="middle" id="zhong-A"><table width="100%" border="0" cellspacing="10" cellpadding="0">
          <tr>
            <td class="song-12-20">如果您对本站有任何疑问、意见、建议、咨询，请联系管理员如果您对本站有任何疑问、意见、建议、咨询，请联系管理员如果您对本站有任何疑问、意见、建议、咨询，请联系管理员如果您对本站有任何疑问、意见、建议、咨询，请联系管理员如果您对本站有任何疑问、意见、建议、咨询，请联系管理员如果您对本站有任何疑问、意见、建议、咨询，请联系管理员</td>
          </tr>
        </table></td>
        </tr>
      <tr>
        <td align="left" valign="top" bgcolor="#F6F6F6" id="zhong-B">&nbsp;</td>
      </tr>
    </table>
     </c:forEach>
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td height="35" align="center" bgcolor="#ffe0a0" id="zhong-A"><table width="90%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td align="right">
				<pg:page formAction="personspace.do?type=comments"
								onePageCount="${comments.onePageCount}"
								resultCount="${comments.resultCount}"
								currentPage="${comments.currentPage}" isShowInfo="true" />
			</td>
          </tr>
        </table></td>
      </tr>
    </table>
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td align="left" valign="top" background="../../../sys/images/angel/images/02-02-06-2.gif"><img src="../../../sys/images/angel/images/02-02-06-1.gif" width="151" height="22" /></td>
      </tr>
    </table>
    <form action="addComment.do"  method="post" id="f2" >
      <table width="850" border="0" cellspacing="0" cellpadding="0" style="margin-top:10px">
      <tr>
        <td width="52%" align="left" valign="top"><textarea id="content" rows="8" cols="58" name="content"></textarea></td>
        <td align="left" valign="top" class="song-12-20"><p><span class="STYLE2">小贴士：</span> <br />
          ★请不要发表攻击性的言论。<br />
          ★如果我们的资料有错误或者不能发表评论，请联系我们给予反馈，<br />
          非常感谢。</p>
          </td>
      </tr>
      <tr>
        <td height="50" align="right" valign="middle"><table style="margin:0px 7px 3px 0px" width="400" border="0" cellpadding="0" cellspacing="0" class="ab10-12">
          <tr>
            <td width="50" align="left">匿名评论              </td>
            <td align="left"><input type="radio" name="niming" value="radiobutton" id="niming" />
            				<input type="hidden" name="promoterId" value="${angel.promoterId }"  />
            </td>
            <td width="130">用户名
              <input id="regId" class="test" name="regId" type="text" onkeyup="value=value.replace(/[^\d]/g,'') " size="10" maxlength="10" onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d]/g,''))" /></td>
            <td width="130">密码
              <input id="userPw" class="test" name="userPw" type="password" onkeyup="value=value.replace(/[^\d]/g,'') " size="10" maxlength="10" onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d]/g,''))" /></td>
            <td><a href="#"></a><a href="${ctx }/jsp/smart/angel/register.jsp&link=personspace"><img src="../../../sys/images/angel/images/button-02.gif" width="32" height="19" border="0" /></a></td>
            </tr>
        </table>
        </td>
        <td align="left" valign="middle"><table style="margin:0px 7px 3px 0px" width="80" border="0" cellpadding="0" cellspacing="0" class="ab10-12">
          <tr>
            <td width="50" align="left"><a id="savebtn" href="#"><img src="../../../sys/images/angel/images/02-02-06-3.gif" width="94" height="30" border="0" /></a></td>
            </tr>
        </table>
        </td>
      </tr>
    </table>
    </form>
    </td>
  </tr>
</table>
<table width="1010" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="79" align="center" valign="bottom" background="../../../sys/images/angel/images/table-bg-two.gif">&nbsp;</td>
  </tr>
  <tr>
    <td height="80" align="center" valign="bottom" background="../../../sys/images/angel/images/table-bg-three.gif"><table width="60%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td align="center" class="ab10-12">Copyright @ 2009 lge.com Inc. All Rights Reserved. LGE 版权所有</td>
      </tr>
      <tr>
        <td height="50" align="center" valign="top" class="song-12-20"><div align="center"></div></td>
      </tr>
    </table></td>
  </tr>
</table>
<table width="950" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="31" align="center" valign="bottom" background="../../../sys/images/angel/images/table-bg-four.gif">&nbsp;</td>
  </tr>
</table>
</body>
</html>

